import Vue from 'vue'
import Router from 'vue-router'
import Index from "../views/index.vue";
import Home from "../views/home/index.vue";
import Allgoods from "../views/allgoods/index.vue";
import detail from "../views/detail/index.vue";

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: "/",
      name: "Index",
      component: Index,
      children: [
        {
          path: "/",
          name: "Home",
          component: Home
        },
        {
          path: "/Allgoods",
          name: "Allgoods",
          component: Allgoods
        }
      ]
    },
    {
      path: "/detail",
      name: "detail",
      component: detail
    }
  ]
});
